<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>拍拍网购物车页</title>
		<!--载入首页的css-->
		<link rel="stylesheet" type="text/css" href="__STATIC__/Index/css/cart.css"/>
		<script src="__STATIC__/Index/js/jquery-1.8.2.min.js" type="text/javascript" charset="utf-8"></script>
		<script type="text/javascript" src="__STATIC__/Index/js/cart.js"></script>
		<script type="text/javascript" src="__STATIC__/Index/js/checked.js"></script>
		<script>
			var URL = "{|U:'Cart/updata_cart'}";
		</script>
		
	</head>
	<body>
		<!--顶部头部开始-->
		<include file="__VIEW__/Common/header"/>
		<!--顶部头部结束-->
	<form action="{|U:'Order/index'}" method="post">
		
	
		<!--购物内容开始-->
		<div id="max_box">
			<!--购物大框开始-->
			<div class="shop_cart">
				<!--当没有物品的时候开始-->
		<if value="!$_SESSION['cart']['goods']">
				<div class="shop_cart_hd">
					<h1>购物车</h1>
					<!--购物图标-->
					<div class="icon state_1">
						<div class="num">0</div>
					</div>
				</div>
				<!--购物内容为空-->
				<div class="shop_cart_bd">
					<div class="shop_cart_empty">
						<p class="tit">您的购物车是空的，赶快行动吧！&nbsp;&nbsp;<a href="{|U:'Index/index'}" style="color: red;" >首页</a></p>
						
				</div>
				<!--当没有物品的时候结束-->
		<else/>
				<!--当有物品的时候开始-->
			<div class="shop_cart_t">
				<!--查看购物车，确认信息背景图开始-->
				<div class="shop_cart_hd_t">
					<h1>购物车</h1>
					<!--购物图标-->
					<div class="icon state_2">
						<div class="num_t">1</div>
					</div>
				</div>
				<!--查看购物车，确认信息背景图结束-->
				<div class="shop_cart_bd_t">
					<div class="bt_opt bt_opt_top group">
						<div class="opt group">
							<span class="check_all">
								<input type="checkbox" checked="checked" name="" id="checktxt" value="" />
							</span>
							<span class="txt">全选</span>
						</div>
					</div>
					<!--选好的商品开始-->
					<div class="shop_list_wrap">
						<div class="shop_unit">
							<div class="shop_unit_main">
								
								<!--循环商品开始-->
							<foreach from="$cartData['goods']" key="$k" value="$v">
								
								<table border="" cellspacing="" cellpadding="">
									<tr id="shopcarTr" tag="shopcarCommTr">
										<td class="good_check">
										<span>
											<input type="checkbox" class="checkone" checked="" name="gidCheck[{$v.id}]" id="" value="1" />
										</span>
										</td>
										<!--图片-->
										<td class="good_pic">
											<a href=""><img src="{$v['options'].thumb}"/></a>
										</td>
										<!--内容-->
										<td class="good_tit">
											<h3><a href="">{$v.name}</a></h3>
										</td>
										<!--尺码-->
										<td class="good_prop">
											<!--循环ul开始-->
										
											<!--循环ul结束-->
											
											<foreach from="$v['options']['spec']" key="$key" value="$value">
											<ul>
												<li>
													<span class="name size">{$value.taname}：</span>
													<span class="value">{$value.gtvalue}</span>
												</li>
											</ul>
											</foreach>
											<!--数量-->
											<ul>
												<li>
													<span class="name size">数量：</span>
												<span class="textarea">
										<input class="num" type="number" min="1" max="{$v.options.store}" value="{$v.num}" />
										<input type="hidden" name="sid" value="{$k}" />
									</span>	
												</li>
											</ul>
										</td>
										<!--价钱-->
										<td class="good_price">
											<div class="price_now">
												¥
												<span>{$v.price}</span>
											</div>
										</td>
										<td class="good_check">
										<span><a onclick="if(confirm('你确认要删除么？')) location.href='{|U:"Content/del",array("id"=>$k)}'"  href="javascript:;">[删除]</a></span>
										</td>
									</tr>
									
									<tr class="tr_bot">
										
										<td colspan="5" style="margin-left: 300px;"><span class="gray">商品总计<span style="color: #C00; font-size: 14px; font-weight: 700;">{$v.total}</span>元</span></td>
										
									</tr>
									
								</table>
							</foreach>
								<!--循环商品结束-->
								
							</div>
						</div>
					</div>
					<!--选好的商品结束-->
				</div>
			</div>
				
				
				
				<!--当有物品的时候结束-->
				
			</div>
			<!--购物大框结束-->
			<!--结算-->
			<div id="account_box">
				
				<div class="check group">
					<span class="sum_txt">商品总计（不含运费）</span>
					<span class="sum_num"> ¥
						<span class="num">{$cartData.total}</span>
					</span>
					<!--结算-->
					<span class="pay_opt_wrap">
						<input class="sub" type="submit" value=""/>
					</span>
				</div>
			</div>
		
			
		</div>
		<!--购物内容开结束-->
	
	</form>			
		
		<!--底部开始-->
		<include file="__VIEW__/Common/footer"/>
		<!--底部结束-->		
	</if>
		
<a class="boxs1" href="#header_top"></a>
		
		
		
		
	</body>
</html>
